
function change_onglet(name)
{
	document.getElementById('onglet_'+anc_onglet).className = 'onglet_0 onglet';
	document.getElementById('onglet_'+name).className = 'onglet_1 onglet';
	document.getElementById('contenu_onglet_'+anc_onglet).style.display = 'none';
	document.getElementById('contenu_onglet_'+name).style.display = 'block';
	anc_onglet = name;
}

function change_valeur() {
	select = document.getElementById("TypeFinition");
	choice = select.selectedIndex;
	
	select_color = document.getElementById("TypeCouleur");
	
	for(var i = 0;i < select_color.options.length;i++) {
		
		if(select_color.options[i].getAttribute("id") == choice + 1) {
			select_color.options[i].setAttribute("style", "display:block");
			document.getElementById('TypeCouleur').selectedIndex = choice;
		}
		
		else {
			select_color.options[i].setAttribute("style", "display:none");
		}
	}
	document.getElementById('Couleur').style.display = 'block';
}

function change_image() {
	select = document.getElementById("TypeChassis");
	choice = select.selectedIndex;
	//alert(choice);
	image = select.options[choice].value;
	//document.getElementById('image').style.display="block";
	document.getElementById('image').innerHTML="<img src='/Symfony/web/bundles/VEKA/images/"+image+"'/>";
	
}

